package com.fsm.common.easyexcel.dto;

import com.alibaba.excel.annotation.ExcelIgnore;
import com.alibaba.excel.annotation.ExcelProperty;
import com.alibaba.excel.annotation.write.style.*;
import lombok.Data;

import java.util.Date;
import java.util.List;
import java.util.Map;

@Data
@HeadRowHeight(value = 25) // 头部行高
@ContentRowHeight(value = 20) // 内容行高
@ColumnWidth(value = 20) // 列宽
/**
 * @OnceAbsoluteMerge 指定从哪一行/列开始,哪一行/列结束,进行单元格合并
 * firstRowIndex 起始行索引,从0开始
 * lastRowIndex 结束行索引
 * firstColumnIndex 起始列索引,从0开始
 * lastColumnIndex 结束列索引
 */
// 例如: 第2-3行,2-3列进行合并
//@OnceAbsoluteMerge(firstRowIndex = 1, lastRowIndex = 2, firstColumnIndex = 1, lastColumnIndex = 2)
public class TSRoleVo {

    // 从此字段数据竖着每两行合并
//    @ContentLoopMerge(eachRow = 2)
    // 从此字段数据竖着每两行，横着每三行合并
//    @ContentLoopMerge(eachRow = 2, columnExtend = 3)
    @ExcelIgnore
    private String id;

    @ExcelProperty(value = {"角色表列表","导出人:${title}","角色名称"} , index = 0)
    @ColumnWidth(25)
    private String roleName;//角色名称

    @ExcelProperty(value = {"角色表列表","导出人:${title}","角色编码"} , index = 1)
    @ColumnWidth(25)
    private String roleCode;//角色编码

    @ExcelProperty(value = {"角色表列表","导出人:${title}","创建时间"} , index = 2)
    @ColumnWidth(25)
    private Date createTime;//创建时间

}
